package com.qiall.omsserver.service.dubbo.convert;

import com.qiall.oms.ability.request.DubboInfoDTO;
import com.qiall.omsserver.data.entity.DubboServiceInfo;
import org.springframework.stereotype.Component;

@Component
public class DubboServiceConvert {
   public DubboInfoDTO trans(DubboServiceInfo dubboServiceInfo){
        DubboInfoDTO dto=new DubboInfoDTO();
        dto.setId(dubboServiceInfo.getId());
        dto.setIp(dubboServiceInfo.getIp());
        dto.setPort(dubboServiceInfo.getPort());
        dto.setServiceName(dubboServiceInfo.getServiceName());
        dto.setServiceGroup(dubboServiceInfo.getServiceGroup());
        dto.setMethods(dubboServiceInfo.getMethods());
        dto.setApplicationName(dubboServiceInfo.getApplicationName());
        dto.setVersion(dubboServiceInfo.getVersion());
        return dto;

    }
}
